package com.huanying.goodjob.job;

import java.io.Serializable;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

@Entity
@Table(name = "rework")
public class Rework implements Serializable {


	/**
	 * 
	 */
	private static final long serialVersionUID = -997583164680399924L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private int id;

	@ManyToOne(cascade = CascadeType.REFRESH, optional = false, fetch = FetchType.LAZY)
	@NotFound(action = NotFoundAction.IGNORE)
	@JoinColumn(name = "jobitem_id")
	private Jobitem jobitem; 
	
	private String img_url; 
	private String img_url2; 
	private String img_url3; 
	private String memo;
	
	@Column(name = "rework_status", nullable = false, columnDefinition = "INT default 0")
	private int rework_status; 
	
	@Column(name = "status", nullable = false, columnDefinition = "INT default 1")
	private int status; // 状态

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public Jobitem getJobitem() {
		return jobitem;
	}

	public void setJobitem(Jobitem jobitem) {
		this.jobitem = jobitem;
	}

	public String getImg_url() {
		return img_url;
	}

	public void setImg_url(String img_url) {
		this.img_url = img_url;
	}

	
	public String getImg_url2() {
		return img_url2;
	}

	public void setImg_url2(String img_url2) {
		this.img_url2 = img_url2;
	}

	public String getImg_url3() {
		return img_url3;
	}

	public void setImg_url3(String img_url3) {
		this.img_url3 = img_url3;
	}

	public String getMemo() {
		return memo;
	}

	public void setMemo(String memo) {
		this.memo = memo;
	}

	public int getRework_status() {
		return rework_status;
	}

	public void setRework_status(int rework_status) {
		this.rework_status = rework_status;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

}